package com.example.androidhw02_1;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.FrameLayout;
import android.widget.ImageView;
import android.widget.TextView;

public class WordListView extends FrameLayout{

	TextView wordView;
	TagAndWords mData;
	
//	public interface OnWordClickListener {
//		public void onWordClick(View v, WordListView data);
//	}
//	
//	OnWordClickListener mListener;
//	
//	public void setOnWordClickListener(OnWordClickListener listener) {
//		mListener = listener;
//	}
	
	public WordListView(Context context) {
		super(context);
		// TODO Auto-generated constructor stub
		LayoutInflater inflater = LayoutInflater.from(context);
		inflater.inflate(R.layout.words, this);
		wordView = (TextView)findViewById(R.id.word);
	}
	
	public void setData(TagAndWords data){
		// TODO Auto-generated method stub
		mData = data;
		wordView.setText(mData.str);
	}


}
